<?php
return [
    'components' => [
        'db' => [
            'class' => 'yii\db\Connection',
            'dsn' => 'mysql:host=localhost;dbname=hongbao',
            'username' => 'root',
            'password' => 'root123456',
            'charset' => 'utf8',
        ],
        'mailer' => [
            'class' => 'yii\swiftmailer\Mailer',
            'viewPath' => '@common/mail',
            // send all mails to a file by default. You have to set
            // 'useFileTransport' to false and configure a transport
            // for the mailer to send real emails.
            'useFileTransport' => true,
        ],
        // wechat 配置
        'wechat' => [
            'class' => 'thanatos\wechat\Wechat',
            'app_id' => 'wx58334e7260478f51',
            'secret' => '5ac6516f0a0070dde453d2658465126b',
            'token' => 'dHVhYm5nemh1',
            'mch_id' => '1311278901',
            'key' => '2kdeenf0qlohvbvxhobdkydmojubaguz',
            'cert_path' => __DIR__ . '/../cert/apiclient_cert.pem',
            'key_path' => __DIR__ . '/../cert/apiclient_key.pem',
            'oauth' => [
                'scopes'   => ['snsapi_userinfo'],
                'callback' => '/index.php?r=site/oauth-callback',
            ],
            'sandbox' => false
        ],
        'sms' => [
            'app_key' => 'LTAI61niIqwsQ74Y',
            'app_secret' => 'Cq98v2b4qcvhqrnBR2Ce64PnszJ4dT',
        ],
    ],
];
